package com.leileimann.tour.mapper;

import com.leileimann.tour.entity.City;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author leileiMann
 * @date 2022/3/7 15:29
 */
@Mapper
@Repository
public interface CityMapper {
    /**
     * 获取所有的城市
     * */
    List<City> getAllCity(@Param("pageNum")Integer pageNum);

    /**获取所有的城市数量*/
    int getNumOfCity();

    /**
     * 按照名字获取城市
     * */
    public City getCityByCityName(@Param("cityname") String cityname);
}
